#pragma once
#ifndef glapp_h_
#define glapp_h_

#include "./glTypes.h"


namespace GLES
{
	class GLContext
	{
	public:
		HWND	   m_hwnd;
		EGLDisplay m_eglDisplay;
		EGLContext m_eglContext;
		EGLSurface m_eglSurface;
		EGLConfig m_eglConfig[1];

	};

	GLContext* getContext();
	Bool CreateGLContext(HWND hwnd);
	Bool DeleteGLContext();

	EGLSurface CreateRenderSurface(GLint w,GLint h,GLuint Format_ = EGL_TEXTURE_RGB);
	Void DestroyRenderSurface(EGLSurface surf);
	Bool BindTexImage(EGLSurface surf);
	Bool ReleaseTexImage(EGLSurface surf);
}
#endif